﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;

namespace FazaDemo.PL.Wpf
{
    public class SuppleDgridCustomizer : IDgridCustomizer
    {

        private readonly Thickness _defDgridThickness;

        private const int ChildIndex = 3;

        private const int RowIndex = 1;

        private const int ColumnIndex = 0;

        private const int ColSpanIndex = 4;

        public SuppleDgridCustomizer()
        {
            _defDgridThickness = new Thickness { Left = 5, Top = 8 };
        }

        public Thickness DefThickness
        {
            get { return _defDgridThickness; }
        }

        public void SetGridPosition(Grid parentGrid)
        {
            Grid.SetRow(parentGrid.Children[ChildIndex], RowIndex);
            Grid.SetColumn(parentGrid.Children[ChildIndex], ColumnIndex);
            Grid.SetColumnSpan(parentGrid.Children[ChildIndex], ColSpanIndex);
        }
    }
}
